Skip to content

Conversation

RogPodge
Copy link
Collaborator

@RogPodge RogPodge commented Oct 2, 2025

Description

The VR Module is obsolete and slated to be removed in a future version of Unity: https://docs.unity3d.com/6000.3/Documentation/ScriptReference/UnityEngine.VRModule.html

This PR removes the dependency of the Input System Package from the VR Module. There is one functional change to the PR, where the AutoXRCameraTracking is disabled during Awake and OnDestroy. This function only works when using the Legacy XR Framework, and does nothing when using the modern XR architecture.

Testing status & QA

N/A

Overall Product Risks

  • Complexity: 1
  • Halo Effect: 1

Comments to reviewers

Removal of the dependency on the VR Module will help make the full removal of the VR Module easier in the future.

Checklist

Before review:

  • Changelog entry added.
    • Explains the change in Changed, Fixed, Added sections.
    • For API change contains an example snippet and/or migration example.
    • JIRA ticket linked, example (case %%). If it is a private issue, just add the case ID without a link.
    • Jira port for the next release set as "Resolved".
  • Tests added/changed, if applicable.
    • Functional tests Area_CanDoX, Area_CanDoX_EvenIfYIsTheCase, Area_WhenIDoX_AndYHappens_ThisIsTheResult.
    • Performance tests.
    • Integration tests.
  • Docs for new/changed API's.
    • Xmldoc cross references are set correctly.
    • Added explanation how the API works.
    • Usage code examples added.
    • The manual is updated, if needed.

During merge:

  • Commit message for squash-merge is prefixed with one of the list:
    • NEW: ___.
    • FIX: ___.
    • DOCS: ___.
    • CHANGE: ___.
    • RELEASE: 1.1.0-preview.3.

After merge:

  • Create forward/backward port if needed. If you are blocked from creating a forward port now please add a task to ISX-1444.

@RogPodge RogPodge requested a review from chris-massie October 2, 2025 23:07
{
"name": "com.unity.modules.vr",
"expression": "1.0.0",
"define": "UNITY_INPUT_SYSTEM_ENABLE_VR"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we also need to remove code that utilize UNITY_INPUT_SYSTEM_ENABLE_VR?

Copy link
Collaborator Author

@RogPodge RogPodge Oct 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There were no code paths left in the InputSystem or Engine repository that utilized the define UNITY_INPUT_SYSTEM_ENABLE_VR

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@codecov-github-com
Copy link

codecov-github-com bot commented Oct 2, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

@@           Coverage Diff            @@
##           develop    #2251   +/-   ##
========================================
  Coverage    76.70%   76.71%           
========================================
  Files          465      465           
  Lines        87919    87911    -8     
========================================
- Hits         67442    67440    -2     
+ Misses       20477    20471    -6     
Flag Coverage Δ
inputsystem_MacOS_2021.3 5.91% <ø> (ø)
inputsystem_MacOS_2021.3_project 78.05% <ø> (+<0.01%) ⬆️
inputsystem_MacOS_2022.3 5.37% <ø> (ø)
inputsystem_MacOS_2022.3_project 74.58% <ø> (+<0.01%) ⬆️
inputsystem_MacOS_6000.0 5.19% <ø> (ø)
inputsystem_MacOS_6000.0_project 76.50% <ø> (+<0.01%) ⬆️
inputsystem_MacOS_6000.2 5.19% <ø> (ø)
inputsystem_MacOS_6000.2_project 76.50% <ø> (+<0.01%) ⬆️
inputsystem_MacOS_6000.3 5.19% <ø> (ø)
inputsystem_MacOS_6000.3_project 76.50% <ø> (+<0.01%) ⬆️
inputsystem_MacOS_6000.4 5.19% <ø> (ø)
inputsystem_MacOS_6000.4_project 76.50% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_2021.3 5.91% <ø> (ø)
inputsystem_Ubuntu_2021.3_project 77.96% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_2022.3 5.38% <ø> (ø)
inputsystem_Ubuntu_2022.3_project 74.39% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_6000.0 5.19% <ø> (ø)
inputsystem_Ubuntu_6000.0_project 76.32% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_6000.2 5.19% <ø> (ø)
inputsystem_Ubuntu_6000.2_project 76.32% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_6000.3 5.19% <ø> (ø)
inputsystem_Ubuntu_6000.3_project 76.32% <ø> (+<0.01%) ⬆️
inputsystem_Ubuntu_6000.4 5.19% <ø> (ø)
inputsystem_Ubuntu_6000.4_project 76.32% <ø> (+<0.01%) ⬆️
inputsystem_Windows_2021.3 5.91% <ø> (ø)
inputsystem_Windows_2021.3_project 78.20% <ø> (+<0.01%) ⬆️
inputsystem_Windows_2022.3 5.37% <ø> (ø)
inputsystem_Windows_2022.3_project 74.72% <ø> (+<0.01%) ⬆️
inputsystem_Windows_6000.0 5.19% <ø> (ø)
inputsystem_Windows_6000.0_project 76.64% <ø> (+<0.01%) ⬆️
inputsystem_Windows_6000.2 5.19% <ø> (ø)
inputsystem_Windows_6000.2_project 76.64% <ø> (+<0.01%) ⬆️
inputsystem_Windows_6000.3 5.19% <ø> (ø)
inputsystem_Windows_6000.3_project 76.64% <ø> (+<0.01%) ⬆️
inputsystem_Windows_6000.4 5.19% <ø> (ø)
inputsystem_Windows_6000.4_project 76.64% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...system/InputSystem/Plugins/XR/TrackedPoseDriver.cs 87.06% <ø> (+1.68%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@unity-cla-assistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@RogPodge RogPodge changed the title Removing dependencies on VRModule FIX: Removing dependencies on VRModule Oct 6, 2025
@RogPodge RogPodge requested a review from K-Tone October 7, 2025 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants